import http from "@/common/http/request";
import {
  musicApkListInterface,
  musicApkAddInterface,
  musicApkUpdateInterface,
} from "./apk.interface";
// apk版本记录列表
export const $musicApkList = (data: musicApkListInterface) => {
  const $http = new http();
  return $http.get({
    url: '/music/apk/list',
    data,
  })
}
// apk版本记录详情
export const $musicApkDetail = (id: string) => {
  const $http = new http();
  return $http.get({
    url: `/music/apk/${id}`,
  })
}
// 新增apk版本记录
export const $musicApkAdd = (data: musicApkAddInterface) => {
  const $http = new http();
  return $http.post({
    url: '/music/apk',
    data,
  })
}
// 修改apk版本记录
export const $musicApkUpdate = (data: musicApkUpdateInterface) => {
  const $http = new http();
  return $http.put({
    url: '/music/apk',
    data,
  })
}
// 删除apk版本记录
export const $musicApkDelete = (data: Array<string>) => {
  const $http = new http();
  return $http.delete({
    url: `/music/apk/${data.join(',')}`,
  })
}